<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
        "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <link rel="stylesheet" type="text/css" href="../../../../css/icon.css">
    <link rel="stylesheet" type="text/css" href="../../../../css/easyui.css">
    <script type="text/javascript" src="../../../../js/jquery-1.7.2.min.js"></script>
    <script type="text/javascript" src="../../../../js/jquery.easyui.min.js"></script>
    <script type="text/javascript" src="../../../../js/easyui-lang-zh_CN.js"></script>
    <script type="text/javascript">
        var datagrid;
        $(function() {
            datagrid=$('#datagrid').datagrid({});
            $.extend($.fn.datagrid.defaults.editors, {
                numberbox: {
                    init: function(container, options){
                        var input =
                                $('<input class="datagrid-editable-input" type="text">'
                                        +'<a class="easyui-linkbutton" href="javascript:void(0);" onclick="t();" style="width:20px">保存</a>')
                                        .appendTo(container);
                        return input.numberbox(options);
                    },
                    getValue: function(target){
                        return $(target).numberbox('getValue');
                    },
                    setValue: function(target, value){
                        $(target).numberbox('setValue',value);
                    }
                }
            });

        });
        function t(){
            datagrid.datagrid('acceptChanges');
            var rows = datagrid.datagrid('getRows');
            for ( var i = 0; i < rows.length; i++) {
                datagrid.datagrid('endEdit', i);
            }
        }
        function export_() {
            var href = "ppm_export.html";
            operateDialog = $("#operateDialog").dialog({title : '导出',width:400,height:150});
            $("#operateIFrame")[0].src=href;
            operateDialog.dialog('open');
        }
    </script>
</head>
<body class="easyui-layout">
<div data-options="region:'north'" style="overflow:hidden;">
    <div class="datagrid-toolbar" style="height: auto">
        <br/>
        <fieldset>
            <legend>Condition/查询条件</legend>
            <table width="100%">
                <tr>
                    <td align="right">SupplierCode供应商编码：</td>
                    <td>
                        <input type="text"/>
                    </td>
                    <td align="right">SupplierName供应商名称：</td>
                    <td>
                        <input type="text"/>
                    </td>
                    <td align="right">Year年份：</td>
                    <td>
                        <input type="text"/>
                    </td>
                    <td align="right">Month月份：</td>
                    <td>
                        <input type="text"/>
                    </td>
                </tr>
            </table>
        </fieldset>
        <br/>
    </div>
</div>
<div data-options="region:'center'">
    <div id="tb">
        <a class="easyui-linkbutton" href="javascript:void(0);" plain="true" iconCls="icon-search">Search查询</a>
        <a class="easyui-linkbutton" href="javascript:void(0);" plain="true" iconCls="icon-undo">Reset重置</a>
        <!--<a class="easyui-linkbutton" href="javascript:void(0);" plain="true" iconCls="icon-export" onclick="export_();">Export导出</a>-->
    </div>
    <table id="datagrid" toolbar="#tb" pagination="true" fit="true" nowrap="false" singleSelect="true">
        <thead>
        <tr>
            <th field="y" width="40" align="center" rowspan="2">Year<br/>年份</th>
            <th field="m" width="40" align="center" rowspan="2">Month<br/>月份</th>
            <th field="1" width="80" align="center" rowspan="2">SupplierCode<br/>供应商编码</th>
            <th field="2" width="100" align="center" rowspan="2">SupplierName<br/>供应商名称</th>
            <th width="600" align="center" colspan="6">MonthData</th>
            <th width="600" align="center" colspan="6">AccumulateData</th>
            <th width="300" align="center" colspan="3">RollingData</th>
        </tr>
        <tr>
            <th field="totalNumM" width="100" align="center">incomingParts</th>
            <th field="QuantityMT" width="100" align="center">TechnicalQuantity</th>
            <th field="ppmMT" width="100" align="center">TechnicalPPM</th>
            <th field="QuantityML" width="100" align="center">LogisticQuantity</th>
            <th field="ppmML" width="100" align="center">LogisticPPM</th>
            <th field="ppmM" width="100" align="center">TotalPPM</th>

            <th field="totalNumA" width="100" align="center">incomingParts</th>
            <th field="QuantityAT" width="100" align="center">TechnicalQuantity</th>
            <th field="ppmAT" width="100" align="center">TechnicalPPM</th>
            <th field="QuantityAL" width="100" align="center">LogisticQuantity</th>
            <th field="ppmAL" width="100" align="center">LogisticPPM</th>
            <th field="ppmA" width="100" align="center">TotalPPM</th>

            <th field="ppmRT" width="100" align="center">TechnicalPPM</th>
            <th field="ppmRL" width="100" align="center">LogisticPPM</th>
            <th field="ppmR" width="100" align="center">TotalPPM</th>
        </tr>
        </thead>
        <tbody>
        <tr>
            <td>2007</td>
            <td>1</td>
            <td>11111</td>
            <td>Kaida 宁波市镇海凯达汽车部件厂</td>
            <td>370408</td>
            <td>1268</td>
            <td>3423</td>
            <td>0</td>
            <td>0</td>
            <td>3423</td>
            <td>370408</td>
            <td>1268</td>
            <td>3423</td>
            <td>0</td>
            <td>0</td>
            <td>3423</td>
            <td>3423</td>
            <td>0</td>
            <td>3423</td>
        </tr>
        <tr>
            <td>2007</td>
            <td>2</td>
            <td>11111</td>
            <td>Kaida 宁波市镇海凯达汽车部件厂</td>
            <td>414961</td>
            <td>2024</td>
            <td>4878</td>
            <td>0</td>
            <td>0</td>
            <td>4878</td>
            <td>785369</td>
            <td>3292</td>
            <td>4192</td>
            <td>0</td>
            <td>0</td>
            <td>4192</td>
            <td>4192</td>
            <td>0</td>
            <td>4192</td>
        </tr>
        <tr>
            <td>2012</td>
            <td>1</td>
            <td>81120</td>
            <td>Bosch Changsha 愽世（长沙）</td>
            <td>2,200</td>
            <td>126</td>
            <td>57,273</td>
            <td></td>
            <td>0</td>
            <td>57,273</td>
            <td>2,200</td>
            <td>126</td>
            <td>57,273</td>
            <td>0</td>
            <td>0</td>
            <td>57,273</td>
            <td>57,273</td>
            <td>0</td>
            <td>57,273</td>
        </tr>
        <tr>
            <td>2012</td>
            <td>1</td>
            <td>91123</td>
            <td>Xuan Ya 上海轩雅印务有限公司</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
            <td>0</td>
        </tr>
        </tbody>
    </table>
</div>
<div id="operateDialog" class="easyui-dialog"
     data-options="iconCls:'icon-save',resizable:true,modal:true,closed: true,collapsible:true,maximizable:true">
    <iframe scrolling="auto" id='operateIFrame' frameborder="0"  src="" style="width:100%;height:100%;"/>
</div>
</body>
</html>